<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        .d1 {
            width: clamp(300px, 150%, 400px);
            height: 200px;
            border: 1px dashed black;
        }

        div:empty {
            background-color: #d9d9d9;

        }

        div:empty::after {
            content: '暂无数据';
        }

        p:empty::after {
            content: '暂无数据';
        }
    </style>
</head>
<body>
<div>
    book
</div>
<div class="d1"></div>

<p></p>

<strong>this is a </strong><span style = "color:#FAFAFA">book</span>
</body>
</html>